import { lazy } from "react";

// const Login=lazy(()=>import('../pages/Login'))
const My=lazy(()=>import('../pages/My'))
const Home=lazy(()=>import('../pages/Home'))
const Layout=lazy(()=>import('../pages/Layout'))
const ShowTime=lazy(()=>import('../pages/ShowTime'))
const Detail=lazy(()=>import('../pages/Detail'))
const Server=lazy(()=>import('../pages/Server'))

// const LoginPage=lazy(()=>import('../pages/LoginPage'))
const Denglu=lazy(()=>import('../pages/Denglu'))
const Collection=lazy(()=>import('../pages/Collection'))



export const tabberRouter=[
    {
        path:'/',
        meta:{
            title:'首页'
        },
        element:<Home/>,
    },
    {
        path:'/my',
        meta:{
            title:'我的'
        },
        element:<My/>,
    }
]
const router=[
    {
        path:'/',
        element:<Layout/>,
        children:[
            ...tabberRouter
        ]
    },
    {
        path:'/showTime',
        element:<ShowTime/>,
    },
    {
        path:'/detail/:id',
        element:<Detail/>,
    },
    {
        path:'/server',
        element:<Server/>,
    },
    {
        path:'/denglu',
        element:<Denglu/>,

    },
    {
        path:'/collection',
        element:<Collection/>,

    }
]

export default router